RIL.APP.PROMPT.confirmCheck( RIL.inSidebar ? RILsidebar.w : window, "Read It Later", "Are you sure you want to open all "+tagList.length+" items tagged '"+tag+"' into new tabs?", "Do not ask me again", check)
)
{
for(i in tagList)
{
RIL.openUrl(tagList[i].url, false, 'tab');
}
if (check.value) RIL.PREFS.set('no-openAllTags-prompt', true);
}
}
},
removeTag : function(e, tag)
{
let tag = tag ? tag : this.getAttribute('tag');
let check = {};
if (RIL.PREFS.getBool('no-removeTag-prompt') ||
RIL.APP.PROMPT.confirmCheck( RIL.inSidebar ? RILsidebar.w : window, "Read It Later", "Are you sure you want to delete the tag '"+tag+"'? This action is not undoable.", "Do not ask me again", check)
)
{
RIL.APP.LIST.removeTag(tag);
if (check.value) RIL.PREFS.set('no-removeTag-prompt', true);
if (RIL.selectedTag == tag) RIL.selectedTag = false;
let itemId = RIL.contextRow.getAttribute('itemId');
let check = {value:false};
if (RIL.PREFS.getBool('no-delete-prompt') || RIL.APP.PROMPT.confirmCheck( RIL.inSidebar ? RILsidebar.w : window, "Read It Later", "Are you sure you want to delete without archiving?", "Do not ask me again", check)) {
if (RIL.selectedListType == 'read')
{
let item = RIL.readList.list[ RIL.readList.iByItem[ itemId ] ];
RIL.APP.SYNC.deleteRemote(item.url, false);
}
else
{
RIL.APP.LIST.mark(itemId, false, false, true);
}
if (check.value) RIL.PREFS.set('no-delete-prompt', true);
if (!RIL.PREFS.getBool('autoMark')) // actions not allowed when auto mark is enabled, otherwise it can chain them together to remove the entire list one by one
{
let action = RIL.PREFS.get('mark');
if (action == 'next') RIL.readNextItemInList(true);
else if (action == 'rand') RIL.readSomethingRandom();
else if (action == 'close' && gBrowser.browsers.length > 1) gBrowser.removeCurrentTab();
}
} catch(e) {Components.utils.reportError(e);}
// brand the document with the item so we can re-add offline pages correctly